package com.bytz.modules.cms.auditBatch.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.bytz.common.system.base.service.ICrudService;
import com.bytz.modules.cms.auditBatch.model.AuditBatchModel;
import com.bytz.modules.cms.user.entity.AuditBatch;
import com.bytz.modules.cms.user.model.IChangeEntity;

import java.util.List;

public interface IAdminAuditBatchService<CE extends IChangeEntity> extends ICrudService<AuditBatch, AuditBatchModel<CE>> {
    /**
     * 分页查询
     */
    IPage<AuditBatchModel> queryPage(Page<AuditBatch> page, QueryWrapper<AuditBatch> initQueryWrapper);

    /**
     * 查询单条
     */
    AuditBatchModel<CE> queryById(String id);

    /**
     * 暂存
     */
    AuditBatchModel<CE> storage(AuditBatchModel<CE> model);

    /**
     * 提交
     */
    AuditBatchModel<CE> submit(AuditBatchModel<CE> model);

    /**
     * 同步Change表到主表
     */
    void syncChange();

    /**
     * 根据导入的excel信息，填充id后返回
     */
    List<CE> importExcel(List<CE> models);
}
